#include "socket.h"

// ./server server_port
int main(int argc, char *argv[])
{
    if (argc != 2)
    {
        cerr << "erro input,please in:xxx port" << endl;
        exit(-1);
    }

    string ip;
    uint16_t port = stoi(argv[1]);

    unique_ptr<Udp> usv = make_unique<Udp>(ip, port);

    usv->Creat_socket();
    usv->Bind();
    usv->Run_server();

    return 0;
}